# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=kdbusaddons
pkgver=5.41.0
pkgrel=0
pkgdesc='Addons to QtDBus'
arch="all"
url='https://community.kde.org/Frameworks'
license="LGPL-2.1"
depends=""
makedepends="extra-cmake-modules qt5-qttools-dev clang doxygen shared-mime-info"
source="https://download.kde.org/stable/frameworks/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz"
subpackages="$pkgname-dev $pkgname-doc $pkgname-lang"
options="!check" # Requires running dbus-daemon

build() {
	cmake \
		-DCMAKE_BUILD_TYPE=Release \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DKDE_INSTALL_LIBDIR=lib \
		-DBUILD_QCH=ON
	make
}

check() {
	cd "$builddir"
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
}

package() {
	cd "$builddir"
	make DESTDIR="${pkgdir}" install
}
sha512sums="52323367b827268e0ed8319184d93066663bbe2b44e1f72833107f8c695ab0024a6c9bbff1fcad66add79d341fe22085c07c0c5f4a0032f0bb3bf9208d95732d  kdbusaddons-5.41.0.tar.xz"
